package com.example.demo.service;

import com.example.demo.model.Books;

import org.springframework.data.domain.Page;

import java.util.List;
public interface BooksService {
    List<Books> getAllBook();
    void addBook(Books book);
    void updateBook(Books book);
    Books getBookById(long id);
    void deleteBookById(long id);
    //分页
    Page<Books> findPaginated(int pageNo, int pageSize, String sortField, String sortDirection);
    //获取作者
    Books findByAuthor(String author);


}